using Google.ProtocolBuffers;
using micromsg.Proto;
using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using System.IO;
using System.Runtime.CompilerServices;
namespace micromsg
{
	[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
	public sealed class GetAppInfoRequest : GeneratedMessageLite<GetAppInfoRequest, GetAppInfoRequest.Builder>
	{
		[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
		public sealed class Builder : GeneratedBuilderLite<GetAppInfoRequest, GetAppInfoRequest.Builder>
		{
			private bool resultIsReadOnly;
			private GetAppInfoRequest result;
			protected override GetAppInfoRequest.Builder ThisBuilder
			{
				get
				{
					return this;
				}
			}
			public override bool IsInitialized
			{
				get
				{
					return this.result.IsInitialized;
				}
			}
			protected override GetAppInfoRequest MessageBeingBuilt
			{
				get
				{
					return this.PrepareBuilder();
				}
			}
			public override GetAppInfoRequest DefaultInstanceForType
			{
				get
				{
					return GetAppInfoRequest.DefaultInstance;
				}
			}
			public BaseRequest BaseRequest
			{
				get
				{
					return this.result.BaseRequest;
				}
				set
				{
					this.SetBaseRequest(value);
				}
			}
			public string AppID
			{
				get
				{
					return this.result.AppID;
				}
				set
				{
					this.SetAppID(value);
				}
			}
			public uint IconType
			{
				get
				{
					return this.result.IconType;
				}
				set
				{
					this.SetIconType(value);
				}
			}
			public Builder()
			{
				this.result = GetAppInfoRequest.DefaultInstance;
				this.resultIsReadOnly = true;
			}
			internal Builder(GetAppInfoRequest cloneFrom)
			{
				this.result = cloneFrom;
				this.resultIsReadOnly = true;
			}
			private GetAppInfoRequest PrepareBuilder()
			{
				if (this.resultIsReadOnly)
				{
					GetAppInfoRequest other = this.result;
					this.result = new GetAppInfoRequest();
					this.resultIsReadOnly = false;
					this.MergeFrom(other);
				}
				return this.result;
			}
			public override GetAppInfoRequest.Builder Clear()
			{
				this.result = GetAppInfoRequest.DefaultInstance;
				this.resultIsReadOnly = true;
				return this;
			}
			public override GetAppInfoRequest.Builder Clone()
			{
				if (this.resultIsReadOnly)
				{
					return new GetAppInfoRequest.Builder(this.result);
				}
				return new GetAppInfoRequest.Builder().MergeFrom(this.result);
			}
			public override GetAppInfoRequest BuildPartial()
			{
				if (this.resultIsReadOnly)
				{
					return this.result;
				}
				this.resultIsReadOnly = true;
				return this.result.MakeReadOnly();
			}
			public override GetAppInfoRequest.Builder MergeFrom(IMessageLite other)
			{
				if (other is GetAppInfoRequest)
				{
					return this.MergeFrom((GetAppInfoRequest)other);
				}
				base.MergeFrom(other);
				return this;
			}
			public override GetAppInfoRequest.Builder MergeFrom(GetAppInfoRequest other)
			{
				return this;
			}
			public override GetAppInfoRequest.Builder MergeFrom(ICodedInputStream input)
			{
				return this.MergeFrom(input, ExtensionRegistry.Empty);
			}
			public override GetAppInfoRequest.Builder MergeFrom(ICodedInputStream input, ExtensionRegistry extensionRegistry)
			{
				this.PrepareBuilder();
				uint num;
				string text;
				while (input.ReadTag(out num, out text))
				{
					if (num == 0u && text != null)
					{
						int num2 = Array.BinarySearch<string>(GetAppInfoRequest._getAppInfoRequestFieldNames, text, StringComparer.get_Ordinal());
						if (num2 < 0)
						{
							this.ParseUnknownField(input, extensionRegistry, num, text);
							continue;
						}
						num = GetAppInfoRequest._getAppInfoRequestFieldTags[num2];
					}
					uint num3 = num;
					if (num3 <= 10u)
					{
						if (num3 == 0u)
						{
							throw InvalidProtocolBufferException.InvalidTag();
						}
						if (num3 == 10u)
						{
							BaseRequest.Builder builder = BaseRequest.CreateBuilder();
							if (this.result.hasBaseRequest)
							{
								builder.MergeFrom(this.BaseRequest);
							}
							input.ReadMessage(builder, extensionRegistry);
							this.BaseRequest = builder.BuildPartial();
							continue;
						}
					}
					else
					{
						if (num3 == 18u)
						{
							this.result.hasAppID = input.ReadString(ref this.result.appID_);
							continue;
						}
						if (num3 == 24u)
						{
							this.result.hasIconType = input.ReadUInt32(ref this.result.iconType_);
							continue;
						}
					}
					if (WireFormat.IsEndGroupTag(num))
					{
						return this;
					}
					this.ParseUnknownField(input, extensionRegistry, num, text);
				}
				return this;
			}
			public GetAppInfoRequest.Builder SetBaseRequest(BaseRequest value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				this.result.hasBaseRequest = true;
				this.result.baseRequest_ = value;
				return this;
			}
			public GetAppInfoRequest.Builder SetBaseRequest(BaseRequest.Builder builderForValue)
			{
				ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
				this.PrepareBuilder();
				this.result.hasBaseRequest = true;
				this.result.baseRequest_ = builderForValue.Build();
				return this;
			}
			public GetAppInfoRequest.Builder MergeBaseRequest(BaseRequest value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				if (this.result.hasBaseRequest && this.result.baseRequest_ != BaseRequest.DefaultInstance)
				{
					this.result.baseRequest_ = BaseRequest.CreateBuilder(this.result.baseRequest_).MergeFrom(value).BuildPartial();
				}
				else
				{
					this.result.baseRequest_ = value;
				}
				this.result.hasBaseRequest = true;
				return this;
			}
			public GetAppInfoRequest.Builder ClearBaseRequest()
			{
				this.PrepareBuilder();
				this.result.hasBaseRequest = false;
				this.result.baseRequest_ = null;
				return this;
			}
			public GetAppInfoRequest.Builder SetAppID(string value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				this.result.hasAppID = true;
				this.result.appID_ = value;
				return this;
			}
			public GetAppInfoRequest.Builder ClearAppID()
			{
				this.PrepareBuilder();
				this.result.hasAppID = false;
				this.result.appID_ = "";
				return this;
			}
			public GetAppInfoRequest.Builder SetIconType(uint value)
			{
				this.PrepareBuilder();
				this.result.hasIconType = true;
				this.result.iconType_ = value;
				return this;
			}
			public GetAppInfoRequest.Builder ClearIconType()
			{
				this.PrepareBuilder();
				this.result.hasIconType = false;
				this.result.iconType_ = 0u;
				return this;
			}
		}
		public const int BaseRequestFieldNumber = 1;
		public const int AppIDFieldNumber = 2;
		public const int IconTypeFieldNumber = 3;
		private static readonly GetAppInfoRequest defaultInstance;
		private static readonly string[] _getAppInfoRequestFieldNames;
		private static readonly uint[] _getAppInfoRequestFieldTags;
		private bool hasBaseRequest;
		private BaseRequest baseRequest_;
		private bool hasAppID;
		private string appID_ = "";
		private bool hasIconType;
		private uint iconType_;
		private int memoizedSerializedSize = -1;
		public static GetAppInfoRequest DefaultInstance
		{
			get
			{
				return GetAppInfoRequest.defaultInstance;
			}
		}
		public override GetAppInfoRequest DefaultInstanceForType
		{
			get
			{
				return GetAppInfoRequest.DefaultInstance;
			}
		}
		protected override GetAppInfoRequest ThisMessage
		{
			get
			{
				return this;
			}
		}
		public BaseRequest BaseRequest
		{
			get
			{
				return this.baseRequest_ ?? BaseRequest.DefaultInstance;
			}
		}
		public string AppID
		{
			get
			{
				return this.appID_;
			}
		}
		public uint IconType
		{
			get
			{
				return this.iconType_;
			}
		}
		public override bool IsInitialized
		{
			get
			{
				return this.hasBaseRequest && this.hasIconType && this.BaseRequest.IsInitialized;
			}
		}
		public override int SerializedSize
		{
			get
			{
				int num = this.memoizedSerializedSize;
				if (num != -1)
				{
					return num;
				}
				num = 0;
				if (this.hasBaseRequest)
				{
					num += CodedOutputStream.ComputeMessageSize(1, this.BaseRequest);
				}
				if (this.hasAppID)
				{
					num += CodedOutputStream.ComputeStringSize(2, this.AppID);
				}
				if (this.hasIconType)
				{
					num += CodedOutputStream.ComputeUInt32Size(3, this.IconType);
				}
				this.memoizedSerializedSize = num;
				return num;
			}
		}
		private GetAppInfoRequest()
		{
		}
		public override void WriteTo(ICodedOutputStream output)
		{
			int arg_06_0 = this.SerializedSize;
			string[] getAppInfoRequestFieldNames = GetAppInfoRequest._getAppInfoRequestFieldNames;
			if (this.hasBaseRequest)
			{
				output.WriteMessage(1, getAppInfoRequestFieldNames[1], this.BaseRequest);
			}
			if (this.hasAppID)
			{
				output.WriteString(2, getAppInfoRequestFieldNames[0], this.AppID);
			}
			if (this.hasIconType)
			{
				output.WriteUInt32(3, getAppInfoRequestFieldNames[2], this.IconType);
			}
		}
		public override int GetHashCode()
		{
			int num = base.GetType().GetHashCode();
			if (this.hasBaseRequest)
			{
				num ^= this.baseRequest_.GetHashCode();
			}
			if (this.hasAppID)
			{
				num ^= this.appID_.GetHashCode();
			}
			if (this.hasIconType)
			{
				num ^= this.iconType_.GetHashCode();
			}
			return num;
		}
		public override bool Equals(object value)
		{
			GetAppInfoRequest getAppInfoRequest = value as GetAppInfoRequest;
			return getAppInfoRequest != null && (this.hasBaseRequest == getAppInfoRequest.hasBaseRequest && (!this.hasBaseRequest || this.baseRequest_.Equals(getAppInfoRequest.baseRequest_))) && (this.hasAppID == getAppInfoRequest.hasAppID && (!this.hasAppID || this.appID_.Equals(getAppInfoRequest.appID_))) && (this.hasIconType == getAppInfoRequest.hasIconType && (!this.hasIconType || this.iconType_.Equals(getAppInfoRequest.iconType_)));
		}
		public override void PrintTo(TextWriter writer)
		{
			GeneratedMessageLite<GetAppInfoRequest, GetAppInfoRequest.Builder>.PrintField("BaseRequest", this.hasBaseRequest, this.baseRequest_, writer);
			GeneratedMessageLite<GetAppInfoRequest, GetAppInfoRequest.Builder>.PrintField("AppID", this.hasAppID, this.appID_, writer);
			GeneratedMessageLite<GetAppInfoRequest, GetAppInfoRequest.Builder>.PrintField("IconType", this.hasIconType, this.iconType_, writer);
		}
		public static GetAppInfoRequest ParseFrom(byte[] data)
		{
			return GetAppInfoRequest.CreateBuilder().MergeFrom(data).BuildParsed();
		}
		private GetAppInfoRequest MakeReadOnly()
		{
			return this;
		}
		public static GetAppInfoRequest.Builder CreateBuilder()
		{
			return new GetAppInfoRequest.Builder();
		}
		public override GetAppInfoRequest.Builder ToBuilder()
		{
			return GetAppInfoRequest.CreateBuilder(this);
		}
		public override GetAppInfoRequest.Builder CreateBuilderForType()
		{
			return new GetAppInfoRequest.Builder();
		}
		public static GetAppInfoRequest.Builder CreateBuilder(GetAppInfoRequest prototype)
		{
			return new GetAppInfoRequest.Builder(prototype);
		}
		static GetAppInfoRequest()
		{
			GetAppInfoRequest.defaultInstance = new GetAppInfoRequest().MakeReadOnly();
			GetAppInfoRequest._getAppInfoRequestFieldNames = new string[]
			{
				"AppID",
				"BaseRequest",
				"IconType"
			};
			GetAppInfoRequest._getAppInfoRequestFieldTags = new uint[]
			{
				18u,
				10u,
				24u
			};
			object.ReferenceEquals(micromsg.Proto.GetAppInfoRequest.Descriptor, null);
		}
	}
}
